package pw.hais.main.main_app.activity;

import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;
import android.view.View;
import android.widget.TextView;

import pw.hais.main.R;
import pw.hais.main.main_app.app.BaseActivity;

/**
 * Created by Hais1992 on 2015/12/11.
 */
public class AuthorActivity extends BaseActivity implements View.OnClickListener {
    private TextView text_msg;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_author);

        text_msg = (TextView) findViewById(R.id.text_msg);
        text_msg.setOnClickListener(this);

        text_msg.setText("作者信息：" +
                "\n\t作者：Hello_海生" +
                "\n\t网址：http://hais.pw" +
                "\n\t邮箱：hais1992@163.com" +
                "\n\n\n" +
                "作品信息：" +
                "\n\t数据来源于网络，如有侵犯请联系作者。" );
    }

    @Override
    public void onClick(View v) {
        switch (v.getId()) {
            case R.id.text_msg:
                Uri uri = Uri.parse("http://hais.pw");
                startActivity(new Intent(Intent.ACTION_VIEW, uri));
                break;
        }
    }
}
